<template>
  <div class="box war m-t-20">
    <div class="area-center bold-size">
      <div class="xi title-center">
        <div class="yuan">{{ this.$route.query.titleIndex }}</div>
        <div class="zhong">{{ this.$route.query.title }}</div>
      </div>
      <!-- 区域 -->
      <div class="wine">
        <div class="small m-t-07">
          ({{ num }})&nbsp;&nbsp;{{ this.$route.query.id }}
        </div>
      </div>
      <div class="richText m-t-10" v-html="context"></div>
    </div>
  </div>
</template>
  
  <script>
import { getCoffeeProById } from "@/api/index";
export default {
  data() {
    return {
      num: sessionStorage.getItem("wine"),
      context: "",
    };
  },
  mounted() {
    getCoffeeProById({
      coffeeproId: this.$route.query.typeId,
    }).then((res) => {
      if (res.data.code == 200) {
        this.context = this.dataHTML(res.data.data.coffeeproText);
      }
    });
  },
};
</script>
  
  <style scoped>
.box {
  width: 100%;
}
/* 版心区域 */
.center {
  margin: 0 1%;
}
.xi {
  width: 100%;
  display: flex;
}
.xi .yuan {
  width: 0.16rem;
  height: 0.16rem;
  /* margin-left: 0.1rem; */
  text-align: center;
  line-height: 0.16rem;
  border-radius: 50%;
  margin-top: 0.05rem;
  border: 1px solid black;
}
.zhong {
  width: 95%;
  height: 100%;
  line-height: 0.3rem;
  padding-left: 0.05rem;
}
.wine {
  width: 100%;
}
h4 {
  width: 90%;
  padding-left: 0.2rem;
}
/* 小盒子区域 */
.small {
  width: 80%;
  padding-left: 0.1rem;
}
</style>